<?php defined('InTuntronKJ') or exit('Access Invalid!');?>



<!--list_header start-->
<div class="list_header">
    <!--list_sort start-->
    <div class="list_sort">
        <div class="list_sort_item">
            <div class="data_check">
                <div class="dc_sub dc_split"><span>从</span></div>
                <div class="dc_sub base_text">
                    <input type="text" class="datepicker" readonly="true" id="order_dateStart" value="" />
                </div>
                <div class="dc_sub dc_split"><span>至</span></div>
                <div class="dc_sub base_text">
                    <input type="text" class="datepicker" readonly="true" id="order_dateEnd" value="" />
                </div>
                <div class="clear"></div>
            </div>
        </div>
        <div class="list_sort_item">
            <div class="base_button">
                <button id="btnOrderListSearch">筛选</button>
            </div>
        </div>
        <div class="clear"></div>
    </div>
    <!--list_sort end-->
</div>
<!--list_header end-->

    <!--list start-->
    <div class="list_table">
        <table>
            <thead>
                <tr>
                    <th style="width: 40px;">序号</th>
                    <th style="width: 40px;">类型</th>
                    <th>金额(元)</th>
                    <!--<th>余额(元)</th>-->
                    <th>交易日期</th>
                    <th>状态</th>
                </tr>
            </thead>
            <tbody>
            <?php if(!empty($output['order_list']) && is_array($output['order_list'])){?>    
            <?php foreach($output['order_list'] as $key=>$value){?>  
           					<tr data-id="1">
                               <td class="center"><span class="gry"><?php echo $key+1?></span></td>
                               <td class="center"><span class="base_blue"><?php echo $output['memberinfo']['type']==0?'会员':'代理' ?></span></td>
                               <td class="center"><span class="base_blue"><?php echo number_format($value['amount'],2) ?></span></td>
                               <td class="center"><span class="base_blue"><?php echo date('Y-m-d H:i:s',$value['actionTime']) ?></span></td>
                               <td class="center">
                               <span class="base_blue">
                               <?php if($output['type'] == "withdraw"){?>
	                               <?php if($value['state'] == 0){?>已到账
	                               <?php }elseif($value['state'] == 1){?>已申请
	                               <?php }elseif($value['state'] == 2){?>已取消
	                               <?php }elseif($value['state'] == 3){?>已支付
	                               <?php }elseif($value['state'] == 4){?>提现失败
	                               <?php }elseif($value['state'] == 5){?>已删除
	                               <?php }?>
	                           <?php }elseif($output['type'] == "recharge"){?>
	                           	   <?php if($value['state'] == 0){?>已申请
	                           	   <?php }elseif($value['state'] == 1){?>已到账
	                           	   <?php }?>
	                           <?php }?>
                               </span>
                               </td>

                           </tr>
            
            <?php }?>
            <?php }else{?>
            <tr>
                <td colspan="5">
                    <!--no_result start-->
                    <div class="no_result list_null">
                                  <div class="nr_icon">&nbsp;</div>
                                  <div class="nr_info">
                                    <h4>没有记录可以显示！</h4>
                                  </div>
                                </div>
                </td>
            </tr>
            <?php }?>
            </tbody>
        </table>
    </div>
    <!--list end-->

    <!--page_nav start-->
    <div class="page_nav">
        <ul>
            <li><a page_index ="1"  page_change="0" class ="GetDataByPageIndex" href="javascript:">首页</a></li>
            <li><a page_index ="<?php echo $output['page']?>" page_change="-1" class ="GetDataByPageIndex" href="javascript:">上一页</a></li>
            <li><a page_index ="<?php echo $output['page']?>" page_change="1" class ="GetDataByPageIndex" href="javascript:">下一页</a></li>
            <li><a page_index ="<?php echo $output['totalpage']?>" page_change="0" class ="GetDataByPageIndex" href="javascript:">最后页</a></li>
              <li><span>第
                  <?php echo $output['page']?>
                      /
                  <?php echo $output['totalpage']?>    
                  页</span></li>
              <li><span>共
                      <?php echo $output['count']?>
                      条记录</span></li>
              <li><a page_index ="<?php echo $output['page']?>" page_change="0" class ="GetDataByPageIndex" href="javascript:">刷新</a></li>
        </ul>
        <div class="clear"></div>
    </div>
    <!--page_nav end--> 
<script type="text/javascript">
    var orderlist_BeginDate = "<?php echo $output['param']['beginDate'] ?>";
    var orderlist_EndDate = "<?php echo $output['param']['endDate'] ?>";
    var orderlist_Type = "recharge";
    var orderlist_ObjId = "recharge_rechargeList";
    init_orderlist();
</script>

